<div>
    <div class="row">
        <div class="col-lg-12">
            <div class="ibox">
                <div class="ibox-title">
                    <h5>资产订单</h5>
                    <div class="ibox-tools" style="top:10px;">
                        <button type="button" class="btn btn-primary btn-sm" v-on:click="_goBack()">
                            <i class="fa fa-times"></i>返回
                        </button>
                    </div>
                </div>
                <div class="ibox-content">
                    <div class="form-group row">
                        <label class="col-sm-1 col-form-label text-right">选择仓库</label>
                        <div class="col-sm-5 ">
                            <label class="col-form-label">{{assetInventoryEditInfo.shName}}</label>
                        </div>
                        <label class="col-sm-1 col-form-label text-right">盘点日期</label>
                        <div class="col-sm-5 ">
                            <label class="col-form-label">{{assetInventoryEditInfo.invTime}}</label>
                        </div>
                    </div>
                    <div class="form-group row">
                        <label class="col-sm-1 col-form-label text-right">盘点说明</label>
                        <div class="col-sm-11 ">
                            <label class="col-form-label">{{assetInventoryEditInfo.remark}}</label>
                        </div>
                    </div>
                </div>
            </div>
        </div>
    </div>
    <div class="row">
        <div class="col-lg-12">
            <div class="ibox">
                <div class="ibox-title">
                    <h5>盘点商品</h5>
                    <div class="ibox-tools" style="top:10px;">
                        <button type="button" class="btn btn-primary btn-sm" v-on:click="_openChooseProductModal()">
                            <i class="fa fa-plus"></i>选择商品
                        </button>
                    </div>
                </div>
                <div class="ibox-content">
                    <table class="footable table table-stripped toggle-arrow-tiny" data-page-size="15">
                        <thead>
                        <tr>
                            <th class="text-center">编号</th>
                            <th class="text-center">名称</th>
                            <th class="text-center">规格</th>
                            <th class="text-center">单价</th>
                            <th class="text-center">账面数量</th>
                            <th class="text-center">盘点数量</th>
                            <th class="text-center">将过期</th>
                            <th class="text-center">耗损</th>
                            <th class="text-center">盘盈</th>
                            <th class="text-center">盘亏</th>
                            <th class="text-center">盘盈金额</th>
                            <th class="text-center">盘亏金额</th>
                            <th class="text-center">操作</th>
                        </tr>
                        </thead>
                        <tbody>
                        <tr v-for="inoutOrderProduct in assetInventoryEditInfo.inoutOrderProducts">
                            <td class="text-center">{{inoutOrderProduct.productId}}</td>
                            <td class="text-center">{{inoutOrderProduct.prodName}}</td>
                            <td class="text-center">{{inoutOrderProduct.specName}}</td>
                            <td class="text-center">{{inoutOrderProduct.price}}</td>
                            <td class="text-center">{{inoutOrderProduct.quantity}}</td>
                            <td class="text-center">
                                <input class="form-control" v-model="inoutOrderProduct.invQuantity" type="number"
                                       @blur="_computeData(inoutOrderProduct)"/>
                            </td>
                            <td class="text-center">
                                <input class="form-control" v-model="inoutOrderProduct.willExpire" type="number"
                                       @blur="_computeData(inoutOrderProduct)"/>
                            </td>
                            <td class="text-center">
                                <input class="form-control" v-model="inoutOrderProduct.attrition" type="number"
                                       @blur="_computeData(inoutOrderProduct)"/>
                            </td>
                            <td class="text-center">{{inoutOrderProduct.invProfit}}</td>
                            <td class="text-center">{{inoutOrderProduct.invLoss}}</td>
                            <td class="text-center">{{inoutOrderProduct.invProfitMoney}}</td>
                            <td class="text-center">{{inoutOrderProduct.invLossMoney}}</td>
                            <td class="text-center">
                                <div class="btn-group">
                                    <button class="btn-white btn btn-xs"
                                            v-on:click="_deleteProduct(inoutOrderProduct)">删除
                                    </button>
                                </div>
                            </td>
                        </tr>
                        </tbody>
                        <tfoot>
                        <tr>
                            <td colspan="13">
                                <ul class="pagination float-right"></ul>
                            </td>
                        </tr>
                        </tfoot>
                    </table>
                </div>
            </div>
        </div>
    </div>
    <div class="row">
        <div class="col-md-10"></div>
        <div class="col-md-2">
            <button class="btn btn-primary float-right" type="button" v-on:click="_doAssetInventory()">
                <i class="fa fa-check"></i>&nbsp;提交
            </button>
            <button type="button" class="btn btn-warning float-right" style="margin-right:20px;"
                    v-on:click="_goBack()">
                <i class="fa fa-close"></i>&nbsp;取消
            </button>
        </div>
    </div>
    <vc:create path="goods/chooseProductAndSpec" emitChooseProduct='assetInventoryEdit'
               emitLoadData='assetInventoryEdit'>
    </vc:create>
</div>